package com.shiyingzi.security.controller;

import javax.annotation.Resource;

import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

import com.shiyingzi.common.PageableData;
import com.shiyingzi.security.model.Role;
import com.shiyingzi.security.service.IRoleService;


@RestController
@RequestMapping(value = "Role")
public class RoleController {
	@Resource(name = IRoleService.BEAN_ID)
	private IRoleService roleService;
	@RequestMapping(value = "/query", method = { RequestMethod.GET, RequestMethod.POST })
	public PageableData<Role> doQuery(int page, int limit, String roleName){
		return roleService.queryUserList(page, limit, roleName);
	}
}
